package com.vnhai.java.jsf.bus.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.vnhai.java.jsf.bus.UserBUS;
import com.vnhai.java.jsf.dao.UserDAO;
import com.vnhai.java.jsf.pojo.Account;

@Service
public class UserBUSImpl implements UserBUS {
	@Autowired
	private UserDAO userDAO;

	@Override
	public String sayHello() {
		return userDAO.sayHello();
	}

	@Override
	public boolean insertUser(Account user) {
		return userDAO.insertUser(user);
	}

	@Override
	public boolean updateUser(Account user) {
		return userDAO.updateUser(user);
	}

	@Override
	public boolean deleteUser(Account user) {
		return userDAO.deleteUser(user);
	}

	@Override
	public Account getUserByID(int userID) {
		return userDAO.getUserByID(userID);
	}

	@Override
	public List<Account> getAllUser() {
		return userDAO.getAllUser();
	}
}
